var o, e = require, t = module, n = exports, i = this && this.__extends || (o = function(t, e) {
    return (o = Object.setPrototypeOf || {
        __proto__: []
    } instanceof Array && function(t, e) {
        t.__proto__ = e;
    } || function(t, e) {
        for (var o in e) e.hasOwnProperty(o) && (t[o] = e[o]);
    })(t, e);
}, function(t, e) {
    function n() {
        this.constructor = t;
    }
    o(t, e), t.prototype = null === e ? Object.create(e) : (n.prototype = e.prototype, 
    new n());
}), a = this && this.__decorate || function(t, e, o, n) {
    var c, r = arguments.length, a = r < 3 ? e : null === n ? n = Object.getOwnPropertyDescriptor(e, o) : n;
    if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) a = Reflect.decorate(t, e, o, n); else for (var i = t.length - 1; 0 <= i; i--) (c = t[i]) && (a = (r < 3 ? c(a) : 3 < r ? c(e, o, a) : c(e, o)) || a);
    return 3 < r && a && Object.defineProperty(e, o, a), a;
};

Object.defineProperty(n, "__esModule", {
    value: !0
});

var r = e("PopItemView"), s = e("GameConfig"), c = cc._decorator, l = c.ccclass, d = c.property, u = function(o) {
    function t() {
        var t = null !== o && o.apply(this, arguments) || this;
        return t.backBtns = [], t.backBtnLayout = null, t;
    }
    return i(t, o), t.prototype.start = function() {
        var e = this;
        o.prototype.start.call(this), this.backBtns.forEach(function(t) {
            t && t.node.on("click", e.onClickBack, e);
        }), this.changeBackBtn(s.GC.backType), this.backBtnLayout && 2 == s.GC.backType && (this.backBtnLayout.y -= 40);
    }, t.prototype.changeBackBtn = function(o) {
        -1 < o && o < this.backBtns.length && this.backBtns.forEach(function(t, e) {
            t && (t.node.active = e == o);
        });
    }, a([ d([ cc.Button ]) ], t.prototype, "backBtns", void 0), a([ d(cc.Node) ], t.prototype, "backBtnLayout", void 0), 
    a([ l ], t);
}(r.default);

n.default = u;